//
//  CSGXSmallModel.m
//  CarSalesMS_GCX
//
//  Created by Ssky on 2016/10/26.
//  Copyright © 2016年 Tony. All rights reserved.
//

#import "CSGXSmallModel.h"

@implementation CSGXSmallModel

- (void)setValue:(id)value forKey:(NSString *)key {
    
    if ([key isEqualToString:@"commArr"]) {
//        self.commArr = [CSGXCommodityModel arrWithArr:value];
        return;
    }
    [super setValue:value forKey:key];
}

+ (NSArray<CSGXSmallModel *> *)arrWithArr:(NSArray *)arr {
    NSMutableArray * mArr = [NSMutableArray array];
    
    for (NSDictionary *dict in arr) {
        CSGXSmallModel * model = [[self alloc] init];
        [model setValuesForKeysWithDictionary:dict];
        [mArr addObject:model];
    }
    
    return mArr.copy;
}

@end
